home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Gold Medal Software 2
/
Gold Medal Software Volume 2 (Gold Medal) (1994).iso
/
wordproc
/
wsm12.arj
/
WORDSMRT.DOC
< prev
next >
Wrap
Text File
|
1993-08-03
|
34KB
|
1,025 lines
WORDSMRT.DOC
Documentation for WordSmart (WSM.EXE), a file-reformatting utility
Version: 1.2
August 3, 1993
WORDSMART and its documentation are Copyright 1992, 1993 by:
Lambert Klein
P.O. Box 611
Wayne MI 48184-0611
Voice telephone: (313) 326-1583 Fax: 313-467-8070
GEnie: L.Klein1
CompuServe: 72010,624
Internet: 72010.624@compuserve.com
AOL: LKlein3990
Member, Association of Shareware Professionals
=======================================================
┌─────────┐
┌─────┴───┐ │ (R)
──│ │o │──────────────────
│ ┌─────┴╨──┐ │ Association of
│ │ │─┘ Shareware
└───│ o │ Professionals
──────│ ║ │────────────────────
└────╨────┘ MEMBER
"This program is produced by a member of the Association of
Shareware Professionals (ASP). ASP wants to make sure that the
shareware principle works for you. If you are unable to resolve
a shareware-related problem with an ASP member by contacting
the member directly, ASP may be able to help. The ASP Ombudsman
can help you resolve a dispute or problem with an ASP member,
but does not provide technical support for members' products.
Please write to the ASP Ombudsman at 545 Grover Road Muskegon
MI 49442 or send a Compuserve message via easyplex to ASP
Ombudsman 70007,3536."
============================================================
┌──────────────────────┐
│ TABLE OF CONTENTS: │
└──────────────────────┘
WordSmart is Shareware ...... page 3
Thanks ...................... page 3
Purpose of WordSmart ........ page 4
Features of WordSmart ....... page 4
Running WordSmart ........... page 5
Basic program syntax ........ page 5
Program options ............. page 7
Options summary ............. page 8
Options in detail ........... page 8
Left margin ......... page 8
Right margin ........ page 9
Removing all EOLs
within paragraphs ... page 11
Preventing reformatting page 12
What happens during
-R processing ....... page 13
Write output file ... page 14
Over-write existing
file ................ page 15
Remove form-feeds ... page 16
Remove multiple spaces page 16
Print registration ... page 16
Remove blank lines (reg) .. page 17
Quiet processing (reg) .... page 17
Piping and redirection ...... page 18
Errorlevels ................. page 20
Example bat file ............ page 20
Registration benefits ....... page 21
page 3
WordSmart is shareware. If you try it out, find it useful, and
go on using it - please register it. Registration is only
$14.00. plus $4.00 shipping and handling.
I hope you find WordSmart useful. If you have any comments,
suggestions, bug reports, and so on, please send them to me
at the address shown above. See the file PROGRAMS.TXT, also
in the archive WORDSMRT.ZIP, for information on my other
shareware, including PrintPlus, my menu-driven dot-matrix
printer control program.
-- Lambert Klein
============================================================
Any registered or trademarked product names mentioned in
this documentation are the property of their respective
owners or publishers.
============================================================
╓┬───────────┬╖
║│ THANKS: │║
╙┴───────────┴╜
I would like to thank Mike Arst for his continuous testing
and debugging of WordSmart. There have been many hours of testing
and coding put into WordSmart.
Thanks goes to the Writer of WordSmart's documentation, who
also happens to be Mike Arst!
page 4
╓┬────────────┐
║│ PURPOSE │
╙┴────────────┘
WordSmart, written entirely in assembly language, is a fast
reformatter for text files.
For instance, WordSmart can increase the line length of text
files created with relatively short lines, perhaps (as with this
file) because the writer assumed you'd be using a typical dot-
matrix printer setup. But if you are using compressed mode for
printing, you might prefer wider lines. WordSmart helps with this
by automatically increasing line lengths for you (or decreasing
them - your choice); you won't have to do so manually in a text
editor or word processor.
FEATURES IN BOTH REGISTERED AND UNREGISTERED
VERSIONS OF WORDSMART
o Accepts input in the form of a source file whose name you
specify on the command line, or accepts input from "standard
input" (i.e., via a "pipe").
o Writes an output file whose name you specify on the command
line; otherwise, writes to "standard output," allowing you
to redirect the results of processing to a file name or
else "pipe" the output to some other program.
o Can over-write an existing file at your option
o Adds to or removes spaces at the left sides of lines.
o Changes the lengths of lines (from 10 characters wide
up to 60,000 characters wide). Can be used to remove "hard"
line breaks within paragraphs completely, preserving the
paragraph-endings themselves.
o Removes form-feed characters.
o Reduces runs of multiple spaces to a single space.
o Returns errorlevels, useful when WordSmart is run from
batch files.
o Removes blank lines from files.
ADDITIONAL FEATURES AVAILABLE ONLY IN THE
REGISTERED VERSION
o "Quiet" mode - no screen display during processing
The program will usually be referred to hereafter in the
documentation simply as "WSM."
page 5
╓┬─────────────────┐
║│ RUNNING WSM.EXE │
╙┴─────────────────┘
WSM can read past an EOF character (Control-Z) and will treat it
as if it were an ordinary character. WSM also treats a NULL (with
a decimal value of 0) no differently from any other character.
Limitations:
Line-ending characters: WSM cannot process files with Unix-style
line endings (line feeds only), nor those with Mac-style line
endings (carriage returns only). The files must have standard DOS
line endings (carriage return plus line feed).
Types of input files: WSM is intended for use only with plain-
text files, not files saved in the "document" format of programs
like WordStar, Microsoft Word, or WordPerfect. Using WSM to alter
such files will probably make them unreadable by the word
processing programs that created them.
╓┬──────────────────────┐
║│ BASIC PROGRAM SYNTAX │
╙┴──────────────────────┘
Typing WSM alone at the DOS prompt brings up a help-screen
containing a summary of the command-line options and information
about the exit codes (errorlevels) WSM returns.
Typical command line:
WSM input [options] > output
Where:
input is the name of the file you want to process;
[options] are one or more of the command-line options
(switches) discussed below; and
> output is an optional command whereby you use DOS
redirection to create an output file.
NOTE: THE NAME OF THE FILE TO BE USED FOR INPUT MUST BE
THE FIRST PARAMETER ON THE COMMAND LINE.
If you do not put the input file name first,
WordSmart will display an error message ("source
path error"), and it will halt without doing any
further work.
The input file name CANNOT contain the DOS
wildcards "*" or "?".
page 6
Other ways to write the command line:
WSM input [options] | another_program
In this kind of command, you use a "pipe" to send WSM's output
not to a file, but to some other program ("another_program" in
the above example) that can read from "standard input."
This also works:
another_program | WSM [options] > output
In this case, you pipe some other program's output to WSM. Note
that in this case, you do NOT give WSM the name of an input file.
You could use WSM's "write output file" option (see below) or use
"> output."
NOTE: There are some risks to be aware of when using redirection
to write output files. They will be discussed in greater
detail in the section called "Piping and output
redirection."
A WSM command line that does not contain a "write output to
file..." command forces the results of processing to be sent only
to "standard output" - to the screen. You can use this to preview
the results of processing and without first having to write an
output file. If you use a program like LIST.COM (a shareware file
viewer by Vernon Buerg), you can pipe output from WSM.EXE to LIST,
thus:
WSM input [switches] | list /s
(LIST's "/s" option is required when it is receiving input via
"pipe" like that.)
page 7
╓┬─────────────────┐
║│ PROGRAM OPTIONS │
╙┴─────────────────┘
WordSmart's functions are all invoked with command-line "switches."
Each "switch" is a hyphen, followed by a single letter (with no
space between the hyphen and the letter). The case of the letter
is unimportant. Both of the following are "legal" forms of the
"-B" switch:
-b -B
Some switches require additional information, which will be
referred to hereafter as an "argument." For example, -W tells
WSM to write an output file; the output file name argument
follows the -W.
You can either add or omit a space between a switch and its
argument. Both of the following are legal ways to add the output
file name argument to the "-w" switch:
-Woutput -W output
There are two possible switch characters: the hyphen and the
forward slash. Either -W or /W would work for the switch used
to specify the output file name. All of the following are "legal"
ways of writing that switch (the file name argument is
represented by the word "output"):
-woutput -w output /woutput /w output
-Woutput -W output /Woutput /W output
page 8
╓┬──────────────────────╖
║│ OPTIONS - SUMMARIZED ║
╙┴──────────────────────╜
Switch Purpose
-L Specify the left margin; must be followed by a number
indicating the number of spaces to add at the left
margin.
-R Specify the right margin; must be followed by a number
indicating the maximum line width.
-W Write output file; must be followed by the name of the
file to write.
-O Over-write an existing file without query. This option
takes no arguments.
-F Remove form-feed characters. This option takes no
arguments.
-S Remove runs of multiple spaces, reducing the string
of spaces to one space only. This option takes no
arguments.
-I Send a WordSmart registration form directly to the
printer. This option takes no arguments.
-B Removes all blank lines past one. -B0 removes all.
-Q "Quiet" mode - no screen display at all during or
after processing. This option takes no arguments.
AVAILABLE ONLY IN THE REGISTERED VERSION.
╓┬───────────────────────────────┐
║│ OPTIONS - DESCRIBED IN DETAIL │
╙┴───────────────────────────────┘
┌────────────────────────────────┐
│ -L ADD SPACES TO LEFT MARGIN │
└────────────────────────────────┘
"-L" is always followed by a two- or three-digit number
indicating the number of spaces to add at the left of each line
of the input file. Example:
-L5 would add 5 spaces to the beginning of each line. If the file
has no left-margin indents at all, the command -L5 would put the
first NON-space character on each line in column 6.
page 9
If there are already spaces at the start of a line, the -L
command adds the additional spaces to them. For example, a file
whose lines are already indented by two spaces would be
indented by seven spaces after you'd used -L5.
In the present version of WSM, the -L command does not REMOVE
spaces from the left margin. Thus, -L0 has no meaning. (Removal
of spaces from the left margin is being considered for a future
version of WordSmart.)
Example - if this is a line in the input file:
Here is a test line
... it looks this way after processing via -L5:
Here is a test line
The first non-space character ("H") is now at column 6.
CAUTION: Numbers higher than 200, used with the -L switch,
might cause corruption in or truncation of the output
file.
┌───────────────────────┐
│ -R NEW RIGHT MARGIN │
└───────────────────────┘
-R is followed by a number 2 to 5 digits long, indicating a new
line width (the number cannot exceed 60000). The number does not
necessarily mean how many characters long the line will be; it is
an "absolute" setting, indicating the right-most COLUMN NUMBER
past which a line must break to a new line. (There's more
information later in this documentation concerning exactly how
WSM makes line-ending decisions).
For instance, if the input file has no left-margin indents at
all, and if you use the -R switch with an argument of 50, the
widest possible output line will be 50 characters long. On the
other hand, if you were to use these commands:
-L10 -R50
... then WSM would add 10 spaces to the left margin and re-
format lines out to column 50 (maximum). In that case, there
would be a maximum of 40 characters on each line, NOT including
the spaces added at the beginning of the line.
page 10
Example - lines that break at column 25:
This is an example of
lines that don't extend
past column 25. The goal
is to re-break them with
the command -R45 so that
they break at column 45.
After processing with the command -R45:
This is an example of lines that don't extend
past column 25. The goal is to re-break them
with the command -R45 so that they break at
column 45.
A nonsensical command like -L40 -R30 would, if taken literally,
add 40 spaces to the start of each line but then try to break all
lines at column 30. If you give WSM an instruction like that, it
ignores the left-margin command entirely and takes only the right-
margin command into account.
If you use an argument less than 10, -R defaults to a value of
10. (There is one notable exception; -R0. See "Removing All Line
Breaks Within Paragraphs," below.)
If you have a text file in which each paragraph is a single long
line, use -R plus a two-digit argument (80 or below) if you want to
make the file more easily readable on-screen. But note: If there
are NO blank lines in such a file, and if none of the lines is
indented, processing it with WSM.EXE will cause the entire file to
be treated as a single paragraph, and you'll lose all paragraph
breaks. The solution would be to add blank lines between paragraphs
and then process the file with WSM.
Where processing begins and ends:
For WordSmart's purposes, a paragraph is one or more lines with
at least one blank line above and below it (them). If a line
appears blank but contains spaces, WSM still treats it as a blank
line. The reason is that, before processing begins, WSM removes any
spaces at the right side of a line - "trailing spaces" - if they
are the last characters before the line boundary. (Thus, a line
containing only spaces has all of its spaces removed before
processing begins.)
page 11
┌────────────────────────────────────────────┐
│ REMOVING ALL LINE BREAKS WITHIN PARAGRAPHS │
└────────────────────────────────────────────┘
Omitting the -R switch entirely from the WordSmart command line,
OR using the command -R0 (zero), tells WSM to remove ALL line
endings within paragraphs in the input file. Using -R0 (or no
-R command at all) is a quick way to turn each paragraph of the
input file into a single long line (see below for exceptions,
however).
This is useful if you will import the text file into a desktop
publishing (DTP) program. You almost always want a DTP program to
make its own line-ending decisions, but its ability to do so is
always defeated by "hard" line breaks within paragraphs. In the
ideal situation, each paragraph is a single long line, and the
only "hard" line breaks in the file are those at the very ends of
the paragraphs.
-R0 (or no -R at all) will preserve the FINAL line boundary of
each paragraph, AS LONG AS THERE IS AT LEAST ONE BLANK LINE ABOVE
AND BELOW EACH PARAGRAPH.
Example: Suppose the input file looks like this:
Line one.
Line two.
Line three.
Line four.
Line five.
Line six.
Result of processing the file with -R0 (or no -R command
at all):
Line one. Line two. Line three. Line four.
Line five. Line six.
page 12
┌─────────────────────────┐
│ PREVENTING REFORMATTING │
└─────────────────────────┘
If, while re-breaking lines in a file, WSM encounters a line
that is already indented from the left margin - using either
spaces or Tab characters - it will not move any part of that
line up to the previous line.
This is a handy way to prevent reformatting of certain lines.
Suppose the input file looks like this:
Line one.
Line two.
Line three.
Line four.
Line five.
Line six.
Line seven.
Line eight.
Line nine.
Result of processing the file with -R0 (or no -R command):
Line one. Line two.
Line three.
Line four. Line five.
Line six. Line seven.
Line eight.
Line nine.
When WSM changes the line length, no part of an already-indented
line will be merged with the one ABOVE it. However, it might be
merged with any NON-INDENTED line BELOW it (whether the latter
occurs depends on the argument to the -R switch - if you have
used -R at all).
Try a few experiments to get a feel for how line-width
reformatting (and exceptions thereto) works.
page 13
┌─────────────────────────────────────┐
│ WHAT HAPPENS DURING "-R" PROCESSING │
└─────────────────────────────────────┘
First, the program strips trailing spaces from all lines.
Then WSM breaks lines at a space or a hyphen. It NEVER breaks up
a word unless the word already contains a hyphen. Space
permitting on a given line, it leaves the part of the word to the
left of the hyphen, and the hyphen itself, on the line and brings
the part of the word to the right of the hyphen down to the next
line. This line:
I won't look the same, post-processing, eh?
... might look like this after WSM finishes with it:
I won't look the same, post-
processing, eh?
If there isn't room on the upper line for that part of the word
(plus the hyphen itself), WSM brings the ENTIRE word down to the
next line, thus:
I won't look the same,
post-processing, eh?
Dashes:
Hyphens sometimes appear in text files to indicate "long" dashes.
WSM treats such character strings - like that -- (or that)
differently from how it deals with hyphens in other situations.
Suppose the input file contains a paragraph like this:
Here are some lines -- Or: Here are some lines -
not many -- with dashes. not many - with dashes.
If you use WSM to increase the file's right margin, the above two
lines might become:
Here are a few lines -- not many -- containing dashes.
Or:
Here are a few lines - not many - containing dashes.
WSM makes this kind of change whether or not there is a space (or
more than one space) between the "dash" and the end of the line.
The key here is that the "dash" must be PRECEDED by a space,
which tells WSM that the hyphen is used as a "dash" and not to
break a word.
page 14
If "dashes"--(like these)--are NOT preceded by spaces, the results
might not be just right in the output file. You might need to do
a bit of editing afterward, removing a space WSM will sometimes
add to the right of such "dashes" in the output file (if the
double hyphen falls at the very end of a line in the input file).
┌────────────────────────┐
│ -W WRITE OUTPUT FILE │
└────────────────────────┘
The -W switch tells WordSmart to write an output file and
requires a file name argument. Omitting the argument causes an
error message to appear, and no processing occurs - except when
you've "piped" some other program's output to WSM for use as its
own input. (There's more information about that in the section
below called "Piping and Output Redirection.")
WSM will NEVER allow you to use the same file name for input and
output when you use the -W switch. (But if you use redirection,
all bets are off - see the piping/redirection information below
for more about this.)
The output file name can contain path information but CANNOT
contain the DOS wildcards "*" or "?".
If you specify a subdirectory that does not exist, WSM halts with
an error message. (If you make that error when using the
REGISTERED version and if you have used the -Q switch for "quiet"
processing, WSM just beeps.)
Example - to process an input file called INPUT.DOC and write
an output file called OUTPUT.DOC:
WSM input.doc -r50 -w output.doc
Over-writing an existing output file or choosing a new name:
If you are not using the -O switch, and if you specify an output
file that now exists, WSM will beep, open a window on the screen
announcing that the file exists, and ask you to make one of three
choices: Select a new file name, over-write the existing file, or
quit.
Press "Q" or ESC to quit at once - no further action.
Press "O" to over-write the existing file (unless it is write-
protected).
page 15
Press "N" to open a window in which you type a new file name.
This also opens a window first containing the message "INSERT
OFF." Pressing ENTER or ESC right away cancels the new-file-name
prompt and tells WSM to quit without doing anything. Or type the
new output file name (including path information, if need be) at
the prompt, then press ENTER to continue processing. WSM then
writes the output file.
(If you decide to over-write the existing file after all, re-type
its name at the new-file-name prompt. WSM presents the "over-
write/new file name/quit" prompt again. Type "O" to over-write
the file.)
The new-output-name prompt supports a few simple editing
keystrokes: The left- and right-arrow keys move the cursor back
and forth across characters in the prompt line without erasing
any characters. BACKSPACE erases the character to the left of the
cursor. DEL erases the character underneath the cursor.
Pressing INS toggles insert-mode on and off (and toggles the text
in the smaller window from "INSERT OFF" to "INSERT ON" and back).
With insert-mode ON, typing characters into the prompt line
pushes any existing characters to the right; with insert-mode
OFF, typing characters into the prompt over-strikes any
characters now there.
You can, initially, type file names much longer than the legal
DOS limit. But if you do so, after you press ENTER, WSM
will beep and inform you that you've typed an illegal file
name. Press ENTER after reading this error message, and you'll
be returned to the new-file-name prompt.
The -W switch is one way to write an output file; using
redirection is another. That method will be discussed shortly.
┌───────────────────────────────┐
│ -O OVER-WRITE EXISTING FILE │
└───────────────────────────────┘
Use the -O switch (no arguments) to suppress WSM's query about
over-writing an existing output file. Example:
WSM input.doc -R50 -w output.doc -o
The -O switch can appear anywhere to the right of the input file
name, and you can use the switch (without causing an error
message) whether or not the output file name already exists.
page 16
┌──────────────────────────────────┐
│ -F REMOVE FORM-FEED CHARACTERS │
└──────────────────────────────────┘
Use -F (no arguments) to remove printer form-feed (FF) characters
(Control-L, decimal value, 12).
If the FF character is by itself on a line, -F deletes the ENTIRE
line (including line boundary). If the FF character appears at
the start or end of a line containing other text, WSM will remove
the FF itself but will not remove any other text on the line
(aside from trailing spaces).
┌─────────────────────────────┐
│ -S REMOVE MULTIPLE SPACES │
└─────────────────────────────┘
Use -S (no arguments) to reduce strings of two or more spaces in
a row to a single space.
This is handy for removing, say, multiple spaces following
punctuation. (Multiple spacing is not desirable if you're sending
the text to a typesetting or DTP system.)
-S is also handy for unjustifying text whose writer has used
multiple spaces to left/right-justify the lines. -S always leaves
a SINGLE space in place of the string of multiple spaces
(including at the beginnings of lines that have been indented by
two or more spaces; this version of WSM is not able to remove ALL
spaces at the start of lines).
┌──────────────────────────────────────┐
│ -I PRINT REGISTRATION FORM/INVOICE │
└──────────────────────────────────────┘
The -I switch takes no arguments. Give the command:
WSM -I
to print a WordSmart registration form on your printer. Make sure
the printer is on and ready before giving the command. WordSmart
does not do a "printer-ready?" check before starting the print
routine.
-I works in both the registered and unregistered versions but is
not noted in the registered version's help-screen.
page 17
╓╥────────────────────────────╖
║║ -B REMOVE BLANK LINES - ║
╙╨────────────────────────────╜
Use -B (no arguments) to remove all blank lines in the file past
one, including lines that begin with spaces.
-B0 removes all blank lines.
NOTE: This command will NOT remove lines that begin with one or
more tab characters but that are otherwise blank (i.e.,
they contain nothing other than tabs or spaces). But lines
that begin with one or more spaces WILL be removed even if
there are tabs after the spaces.
╓╥─────────────────────────────────────────────────────╖
║║ -Q "QUIET" PROCESSING - *REGISTERED VERSION ONLY* ║
╙╨─────────────────────────────────────────────────────╜
Use -Q (no arguments) to suppress all WordSmart screen displays.
If there is any error during processing, you are alerted to the
problem only via a beep. -Q is useful if you run WSM from batch
files and want full control over the screen displays during
execution of the batch files.
In some situations, WSM will not beep if there is an error when
you're using the -Q switch. But you can check for errors by
testing for the exit code (errorlevel) WSM returns (errorlevels
are discussed shortly).
page 18
╓┬───────────────────────────────┐
║│ PIPING AND OUTPUT REDIRECTION │
╙┴───────────────────────────────┘
WordSmart can take as input either a file whose name you
specify on the command line, or the output of some other
process - via "piping."
Suppose you use an automated search/replace program called SR that
can write to standard output or can read from standard input.
Examples:
SR command | WSM [options]
Or:
WSM [options] | SR command
In the first case, you pipe the SR's output to WSM. In the
second, you pipe WSM's output to SR.
When you tell WSM to get its information from standard input, do
NOT put the name of an input file into the WSM command line.
Given a command like the following:
another_program | WSM input.doc [options]
... WSM completely ignores the piped information and reads
only INPUT.DOC, instead.
Writing output files using redirection:
You can use WSM's -W switch to write an output file, or you can
use DOS redirection (">" and ">>").
Using ">" can be risky. Suppose you'd like to process the file
INPUT.DOC and over-write it with the changed version - same file
name - rather than write a new file. So you give this command:
WSM input.doc [options] > input.doc
Result: A file called INPUT.DOC that is only ZERO BYTES LONG.
Definitely not what you wanted.
Reason: DOS (not WSM) creates the zero-byte file. Then WSM reads
the input file. But by that time, there isn't anything to read
other than a zero-byte file! If you have only one copy of
INPUT.DOC, you'll have lost it for good.
page 19
Don't EVER try to over-write your existing file that way. Play
it safe; process the file as follows:
WSM input.doc [options] > output.doc
I.e., use a different output file name (or forget redirection
and use WordSmart's -W switch).
The following sort of command is also risky:
WSM [options] < input.doc > input.doc
It might work well at some times, but destroy or corrupt your
input file at other times. The following is much safer:
WSM [options] < input.doc > output.doc
The following doesn't work, either:
WSM input.doc [options] -w output.doc > new.doc
You think, perhaps, that you can create two identical output files
at the same time - OUTPUT.DOC and NEW.DOC? Doesn't work. In that
case, WSM writes OUTPUT.DOC and DOS itself writes a zero-byte file
called NEW.DOC.
Redirection and screen displays:
When you use redirection, you don't give WSM.EXE enough
information to create complete screen displays. If you pipe
information to WSM, it doesn't display a proper input file name -
because there isn't an input file to begin with.
If you write an output file via redirection, the WSM screen
display doesn't show any output file name.
page 20
╓┬─────────────┐
║│ ERRORLEVELS │
╙┴─────────────┘
WordSmart returns 7 different exit codes (errorlevels):
Code Meaning
0 Processing was successful
1 "Read" error - couldn't find the specified input file.
2 Can't write the output file because you gave it the same
name as the input file.
(NOTE: Using output redirection completely defeats
WordSmart's ability to check for that kind of error.)
3 Can't over-write the specified output file - it now
exists (and you haven't used the -O switch).
4 Can't write the specified output file - you've given
a drive and/or path name that doesn't exist. WSM also
returns this errorlevel if you try to write an output
file to a floppy drive that isn't ready, or to a write-
protected disk.
5 Can't over-write the existing file because it's write-
protected.
255 Returned if you type WSM without any command-line
options at all.
The errorlevels become most useful when you're running WSM from a
batch file and are using the -Q ("quiet") switch, in which case
there are no screen displays at all.
See the file WORDSMRT.BAT for a simple example of checking for the
return of errorlevels in a batch file. The batch file uses WSM's
-Q switch, which will not function if you don't yet have the
registered version of WSM; but you will still be able to see how
the errorlevel-checking works. (The presence of -Q in the command
line will not cause the unregistered version to return any error
messages.)
╓┬───────────────────┐
║│ ABOUT EXAMPLE.BAT │
╙┴───────────────────┘
EXAMPLE.BAT, included in the WordSmart distribution archive, is a
simple batch file that shows the results of processing using
various -R commands.
EXAMPLE.BAT uses the file you're reading right now (WORDSMRT.DOC)
for input, and it writes an output file called XXXXXXX_._XX. Once
you're done using EXAMPLE.BAT, be sure to delete XXXXXXX_._XX.
page 21
Type EXAMPLE at the DOS prompt for information on the batch
file's syntax.
I hope you find WordSmart useful. I will greatly appreciate your
registering it.
-- Lambert Klein
┌┬───────────────────────────────────────────────────┬┐
││ Documentation by Mike Arst, CompuServe 70403,1337 ││
└┴───────────────────────────────────────────────────┴┘
┌┬────────────────────────┬┐
││ REGISTRATION BENEFITS: ││
└┴────────────────────────┴┘
You have a 30-day evaluation period to try out WordSmart.
After 30 days you must register WordSmart to legally continue
its use.
When you register WordSmart you receive the following:
1. A disk with the Registered version of WordSmart,
branded with your name and serial number.
2. Other Shareware and Freeware.
3. A printed manual for WordSmart.
4. Voice, mail and Email support.
5. Any extra features that are added to WordSmart. This
will include the the -Q switch for quiet screen during
processing.
6. The great feeling of registering a high-caliber program
at a very reasonable price!
To print the registration form type WSM -I [Enter]
at the Dos prompt.
Thank you for your support!
Lambert Klein
PO Box 611
Wayne MI 48184-0611
You can register WordSmart on CompuServe also. Just "GO SWREG".
Program Title: WordSmart
Registration ID: 562